<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@page isELIgnored="false"%>

<%  
    String path = request.getContextPath();  
    String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";  
%> 

<%-- <%  
    String path = request.getContextPath();  
    String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";  
    response.sendRedirect(basePath+"logincookie");  
%>  --%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>树</title>
</head>

  <link rel="stylesheet" type="text/css" href="<%=path%>/easyui/themes/default/easyui.css">
  <link rel="stylesheet" type="text/css" href="<%=path%>/easyui/themes/icon.css">
  <script type="text/javascript" src="<%=path%>/easyui/jquery-1.8.2.min.js"></script>
  <script type="text/javascript" src="<%=path%>/easyui/jquery.easyui.min.js"></script>
  <script type="text/javascript" src="<%=path%>/easyui/sys.js"></script>
  <script type="text/javascript" src="<%=path%>/easyui/locale/easyui-lang-zh_CN.js"></script>
  <script type="text/javascript" src="<%=path%>/js/jquery-form.js"></script>
<body class="easyui-layout">  



<script type="text/javascript">

	
	$(function(){
	
	 $("#tree").tree({
	    	url:'menueTree',
	    	idFiled:'code',
	    	textFiled:'name',
	    	parentField:'pcode',
	    	onClick:function(node){
	    		var menu =$("[name='menu']").val();
	    		var flag=$("#tab").tabs("exists",node.name);
	    		if(flag){
	    			$("#tab").tabs("select",node.name);
	    		}else{
	    			$("#tab").tabs('add',{
	    				title:node.name,
	    				closable:true,
	    				href:node.url+"?menu="+menu
	    			});
	    		}
	    	}
	    });
	
	});
	
	function tuichu() {
		location="tuichu";
	}

</script>
	<input type="hidden" name="menu" value="${user.menu}" >
    <div data-options="region:'north',title:'',split:true" style="height:100px;">
    	<P align=center><b>
	  			<font size="+3" style="line-height:42px;" >某某系统管理页面</font><br></b>
	  	</P>
	  	<P align=center><font size="+1">${user.user} 欢迎您进入,本页面共${user.i}人浏览                <!-- <a id="tuichu" onclick="tuichu()" href="javascript:void(0)" class="easyui-linkbutton" data-options="iconCls:'icon-no'">退出登录</a> -->  </font></P>
    </div>  
    <div data-options="region:'south',title:'South Title',split:true" style="height:50px;"></div>  
    <div data-options="region:'west',title:'导航',split:true" style="width:200px;">
    <ul id="tree"></ul>
    </div>  
    <div data-options="region:'center',title:''" style="padding:5px;">
    	 <div id="tab" class="easyui-tabs" fit="true">
           <div title="首页" style="text-align: center">
              	<h3 style=""><font size="+2">欢迎进入药店管理系统</font></h3>
           </div>
      	 </div>
    </div>
</body>
</html>